package com.traffic.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.traffic.entity.Admin;
import com.traffic.entity.QueryResult;

import java.util.List;

/**
 * Created by IntelliJ IDEA.
 * User: KingRainGrey
 * Date: 2020/9/8
 */
public interface AdminService extends IService<Admin> {
    Admin register(String account, String password);

    Admin register(String account, String password, String phone, Long role);

    Admin editAdminInfo(Admin admin);

    String login(String account, String password);

    boolean logout();

    Admin get(String account);

    Boolean delete(Long adminId);

    QueryResult queryAdmins(Integer currentPage, Integer pageSize);

    Integer ban(List<Long> idList);

    Integer pass(List<Long> idList);

    Integer deleteList(List<Long> idList);

    QueryResult query(String queryInfo);

    Admin queryById(Long id);

    Integer editAdmin(Long id, String name, String phone, Long role, Integer status, String password);

    Boolean ownEditInfo(Long id, String name, String phone, String p1, String p2);
}
